/*
 *  imageManager.h
 *  graphicsExample
 *
 *  Created by 真鍋 大度 on 11/04/25.
 *  Copyright 2011 Rhizomatiks. All rights reserved.
 *
 */

#pragma once
#include "ofMain.h"
#include "ofxVectorMath.h"
#include "stroke.h"
#include "box2dCustom.h"

class imageManager{
public:
	void setup(){
		
		DIR.setVerbose(false);
		int nFolders = DIR.listDir("imgs");
		
		for (int i=0; i<nFolders; i++) {
			int nImages = SUB_DIR.listDir("imgs/"+DIR.getName(i));
			for(int i = 0; i < nImages; i++){
				ofImage tmpImg;
				tmpImg.loadImage(SUB_DIR.getPath(i));
				imgs.push_back(tmpImg);		
				tmpImg.clear();
			}
			vimages.push_back(imgs);
			imgs.clear();
		}
		cout << "vimages " << vimages.size() << endl;		
	}
	void update(){
		
	}
	
	void draw(){
		
	}
	vector <ofImage> imgs;		
	
	vector< vector<ofImage> > vimages;	
	ofxDirList	 SUB_DIR;
	ofxDirList   DIR;	
	
};